#pragma once

#include "Color.h"
#include "Shape.h"

class AbstractFactory
{
public:
    AbstractFactory()          = default;
    virtual ~AbstractFactory() = default;

public:
    virtual Color *getColor() const = 0;
    virtual Shape *getShape() const = 0;
};

class ConcreteFactory1 : public AbstractFactory
{
public:
    Color *getColor() const override
    {
        return new Green();
    }
    Shape *getShape() const override
    {
        return new Circle();
    }
};

class ConcreteFactory2 : public AbstractFactory
{
public:
    Color *getColor() const override
    {
        return new Red();
    }
    Shape *getShape() const override
    {
        return new Rectangle();
    }
};
